/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package ua.epam.muzalevskiy.third_project.knife;

/**
 * This class include blade length parameters.
 *
 * @author Muzalevskiy Vitaliy
 */
public class BladeLength {
    
    /**
     * Units of current knife blade length.
     */
    private Units units;
    
    /**
     * Length of current knife blade.
     */
    private int length;

    /**
     * Constructor of <code> BladeLength </code> class.
     *
     * @param unit - units of current knife blade length.
     * @param length - length of current knife blade.
     */
    public BladeLength(Units unit, int length) {
        this.units = unit;
        this.length = length;
    }

    /**
     * @return the unit
     */
    public Units getUnit() {
        return units;
    }

    /**
     * @return the length
     */
    public int getLength() {
        return length;
    }
    
    @Override
    public String toString() {
        return "length=" + length + '(' + units + ')';
    }
}
